﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading;
using System.Windows.Input;

using DanielVaughan.ComponentModel;
using DanielVaughan.Windows;

namespace CalciumTemplateApp.Views.Examples
{
	public class PersistencyExampleViewModel : UserViewModel
	{
		public PersistencyExampleViewModel() : base("persistency example")
		{
			/* Intentionally left blank. */
		}

		string exampleText1;

		[Stateful(ApplicationStateType.Persistent)]
		public string ExampleText1
		{
			get
			{
				return exampleText1;
			}
			set
			{
				Assign(() => ExampleText1, ref exampleText1, value);
			}
		}

		string exampleText2;

		[Stateful(ApplicationStateType.Transient)]
		public string ExampleText2
		{
			get
			{
				return exampleText2;
			}
			set
			{
				Assign(() => ExampleText2, ref exampleText2, value);
			}
		}
	}
}
